Auto merge of #4832 - andreastt:dumb_terminal_progress, r=alexcrichton
authorbors <bors@rust-lang.org>
Tue, 19 Dec 2017 00:41:01 +0000 (00:41 +0000)
committerbors <bors@rust-lang.org>
Tue, 19 Dec 2017 00:41:01 +0000 (00:41 +0000)
commit576ac63f5a919abe83d1c1f8008c54a20f8ee054
treedcbc5e1682c0b73afddba92def5fd1b8fed5c9dd
parent4bbfc70da98bc00edb5c0e04d32326b270753f2e
parent274f9ce40d300be5ee898809bfeee027a31afc48
Auto merge of #4832 - andreastt:dumb_terminal_progress, r=alexcrichton

util/progress: no progress reporting in dumb terminals

cargo should not assume that all terminals have direct access to
the terminal.  Dumb terminals are those that can interpret only a
limited number of control codes (CR, LF, &c.) and the escape codes
used by the progress bar breaks output in these by asserting control
over the cursor position to draw a bar.

A dumb terminal is identified by the TERM output variable being set to
"dumb".  This adds a direct check for this in src/cargo/util/progress.rs
because TERM=dumb does not imply the same as the -q flag.